package com.littleHan.brushQuestions.web.userCenter.service;


import com.littleHan.brushQuestions.exception.FailedSettingException;
import com.littleHan.brushQuestions.web.start.pojo.Comment;
import com.littleHan.brushQuestions.web.start.pojo.GeneralUser;
import com.littleHan.brushQuestions.web.start.pojo.Topic;
import com.littleHan.brushQuestions.web.userCenter.pojo.Pagination;

import java.util.Map;

public interface AuditorUserCenterService {

    /**
     * 获取没有被审核的题目信息
     * @param pagination 分页对象
     * @return
     */
    Map<String,Object> getNoCheckTopic(Pagination pagination);

    /**
     * 审核通过，通知用户，并将isCheck改为1
     * @param topic 携带题目id和该道题的用户id
     */
    void topicPassed(Topic topic) throws FailedSettingException;

    /**
     * 审核未通过，通知用户，并将题目删除
     * @param topic 携带题目id和该道题的用户id
     */
    void topicUnPassed(Topic topic)throws FailedSettingException;

    /**
     * 获取没有审核的评论
     * @param pagination 分页信息
     * @return
     */
    Map<String, Object> getNoCheckComment(Pagination pagination);

    /**
     * 审核评论通过
     * @param comment 评论信息
     * @return
     */
    void commentPassed(Comment comment) throws FailedSettingException;

    /**
     * 审核评论未通过
     * @param comment 评论信息
     * @return
     */
    void commentUnPassed(Comment comment) throws FailedSettingException;

    /**
     * 获取到当前用户信息
     * @param userId 用户id
     * @return
     */
    GeneralUser getUserInfoByUserId(String userId);
}
